//
//  BaseViewController.m
//  Camera
//
//  Created by aaaaaa on 16/8/9.
//  Copyright © 2016年 葛海一. All rights reserved.
//

#import "BaseViewController.h"

@interface BaseViewController ()

@end

@implementation BaseViewController

- (void)viewDidLoad {
    [super viewDidLoad];

    [self config];
 
    
}


// 基本设置
- (void)config{
    self.automaticallyAdjustsScrollViewInsets = NO;
    self.view.backgroundColor = [UIColor whiteColor];
}

// 返回的navigationItem
- (void)createLeflBarItem{
    self.navigationItem.leftBarButtonItem = [[UIBarButtonItem alloc] initWithImage:[[UIImage imageNamed:@"btn_back_n"] imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal] style:UIBarButtonItemStyleDone target:self action:@selector(backAction:)];
}

- (void)backAction:(UIBarButtonItem *)bar{
    [self.navigationController popViewControllerAnimated:YES];
}

// 设置状态栏是否隐藏 使用之前设置self.isHiddenStatus 默认NO
- (BOOL)prefersStatusBarHidden {
    return self.isHiddenStatus;
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
